package com.briup.jd2511.jd2511bookstore.service.impl;

import com.briup.jd2511.jd2511bookstore.mapper.UserLogMapper;
import com.briup.jd2511.jd2511bookstore.pojo.UserLog;
import com.briup.jd2511.jd2511bookstore.service.UserLogService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

@Service
public class UserLogServiceImpl implements UserLogService {

    @Autowired
    private UserLogMapper userLogMapper;

    @Override
    @Transactional(propagation = Propagation.REQUIRES_NEW)
    public void addUserLog(UserLog userLog) {
        userLogMapper.insert(userLog);
    }
}
